package com.bookcity.service;

import com.bookcity.pojo.BriefBook;
import com.bookcity.pojo.Comment;
import com.bookcity.pojo.DetailBook;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * BookService
 *
 * @Author : lostprobe
 * @Date : 2022/6/30 18:25
 * @Brief : BookService
 */
public interface BookService {

    DetailBook getBookById(@Param("bid") long bid);
    List<Comment> getComment(@Param("bid") long bid);
    List<BriefBook> listBook(@Param("pn") int pn, @Param("rn") int rn, @Param("zone") int zone, @Param("type") int type, @Param("other") int other);
    List<BriefBook> searchBooksByName(@Param("bookname") String bookname);
    void updateBookStockById(long bid, int num);
    int addOnBook(DetailBook detailBook);
    int deleteByBid(@Param("bid") long bid);
}
